{% extends "qa_base.html" %}

{% block content %}
<div id="wrapper"> 
            <div id="room"> 
                <div id="CAFull"> 
					<div class="tabBar"> 
    						<div class="headUsers">用户列表</div> 
    						<div class="tabsA"><a href="/qa/questions/users/?sort=jointime" {%if content == 'jointime'%}class = 'on'
                            {%endif%} title="newest members">最新加入</a><a href="/qa/questions/users/?sort=name" {%if content == 'name'%}class = 'on'{%endif%} title="sorted by username">用户名</a></div> 
 					</div> 
					<div id="main-body" style="width:100%"> 
    				<p></p> 
    					<div class="userList"> 
                        {%  for user in	user_list %}
       					    <div class="user"> 
            					<ul> 
                                      <li class="thumb"><a href="/qa/questions/users/{{user.id}}/"><img class="gravatar" width="32" height="32" src="{% if user.image %}/{{user.image}}{%endif%}{%if not user.image%}/user_image/2011/08/05/test-image_1.jpg{%endif%}" alt="{{user.name}}'s  image" /></a></li> 
                					<li><a href="/qa/questions/users/{{user.id}}/">{{user.name|slice:":5"}}{%if user.name|length >= 5%}..{%endif%}</a></li>
                                    <li><span title="{{user.questions.all|length}} questions">{{user.questions.all|length}}</span><span class="badge1">&#9679;</span><span class="badgecount" title = '{{user.answer_set.all|length}} answers'>{{user.answer_set.all|length}}</span></li>
           						</ul> 
        					</div> 
  						{% endfor %}
    					</div> 
					</div> 
                </div> 
                <div id="tail" style="clear:both;"> 
                    
 <div class="pager">
                    <p class="paginator" >
                        {% if LastNum >= 1 %}
                       <span class="next"><a href="/qa/questions/users/pages/{{LastNum}}" title="上一页">&laquo; 上一页</a></span>
                        {% endif %}
                        {% for PageNum in PageList%}
                        {% if PageNum == CurrentNum %}
                        <span class="curr this_page" >{{PageNum}}</span>
                        {% else %}
                        <a class="page" href="/qa/questions/users/pages/{{PageNum}}" >{{PageNum}}</a>
                        {% endif %}
                        {% endfor %}
                        {% if NextNum <= PageTotalNum %}
                        <span class="next"><a href="/qa/questions/users/pages/{{NextNum}}" title="下一页">下一页 &raquo;</a></span>
                        {% endif %}
                    </p>
                </div>           
 
                </div> 
            </div> 
            <div class="spacer3"></div> 
        </div> 
{% endblock %}